<?php
/**
 * @ClassName: MerchantEnum
 * @Description: TODO
 * @author: gydtrade
 * @Date: 2025-09-10 14:05
 * @Version: V1.0.0
 */

namespace app\common\enum;

class MerchantEnum
{
    const shop = 1;//联盟商家
    const water = 2;//水站商家

    /**
     * 商家（店铺）类型
     * @param $level
     * @return string|string[]
     */
    public static function storeTypeText($level)
    {
        $desc = [
            MerchantEnum::water => '水站',
            MerchantEnum::shop => '联盟',
        ];
        if ($level === true) {
            return $desc;
        }
        return $desc[$level] ?? $level;
    }

}